

#import "AppDelegate.h"
#import "JASidePanelController.h"
#import "LeftViewController.h"
#import "HomeViewController.h"
#import "QcNewFeatureViewController.h"

@interface AppDelegate ()



@end

@implementation AppDelegate


- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
    
    self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
    
    QcNewFeatureViewController *featureVC = [[QcNewFeatureViewController alloc] init];
    
    //实例化
    self.viewController = [[JASidePanelController alloc] init];
    
    // 左
    self.viewController.leftPanel = [[LeftViewController alloc] init];
    
    // 右
    HomeViewController *homeVc = [[HomeViewController alloc] init];
    self.viewController.centerPanel = [[UINavigationController alloc] initWithRootViewController:homeVc];
    
    NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
    
    BOOL isFirst = [defaults boolForKey:@"kisFirstEnter"];
    
    if (!isFirst) {
        self.window.rootViewController = featureVC;
    }else{
        //显示window
        self.window.rootViewController = self.viewController;
    }

    [self.window makeKeyAndVisible];
    
    return YES;
}






@end
